package chap02.ClassData;

/**
 * 用来存储数据对象的类叫做容器类，通常容器类不仅存储数据，
 * 并且提供访问数据的方法，和诸如排序等复杂的操作
 * Created by root on 2017/4/26.
 */
public class ClassDataArrayApp {

    public static void main(String[] args){
        int maxSize = 10;
        ClassDataArray arr = new ClassDataArray(maxSize);
        arr.insert(new Person("Evans", "Patty", 1));
        arr.insert(new Person("Smith", "Lorraine", 1));
        arr.insert(new Person("Yee", "Tom", 1));
        arr.insert(new Person("Adams", "Henry", 1));
        arr.insert(new Person("Hashimoto", "Sato", 1));
        arr.insert(new Person("Stimson", "Henry", 1));
        arr.insert(new Person("Velasquez", "Jose", 1));
        arr.insert(new Person("Lamarque", "Henry", 1));
        arr.insert(new Person("Vang", "Minh", 1));
        arr.insert(new Person("Creswell", "Lucinda", 1));
        arr.display();
//        arr.insert(86);
//        arr.display();
//        arr.display();
        System.out.println(arr.find("Stimson"));
        arr.delete("Smith");
        arr.display();
    }
}
